<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>

<body>
    <script>
        //【1】prototypeIsEnumerable用来判断给定的属性是否可以被for..in语句给枚举出来。看下面代码：
        var obj = {
            name: "objName"
        }
        for (var i in obj) {
            console.log(i);
        };


        // 判断“constructor”是否可以被枚举，输出false说明无法被枚举出来。
        console.log(obj.propertyIsEnumerable("constructor")); //false
    </script>
</body>

</html>